package service.edu.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;
import service.edu.result.R;

import java.util.List;

@Component//此处作用:防止在其他位置注入VodClient时idea报错
@FeignClient(name = "service-vod",fallback = VodClientHystrix.class)
public interface VodClient {
    //根据视频id删除阿里云视频
    @DeleteMapping("/vod/deleteVideo/{videoSourceId}")
     R deleteVideoByVideoId(@PathVariable("videoSourceId")String videoSourceId);

    //根据多个视频id删除多个阿里云视频
    @DeleteMapping("/vod/deleteVideoBatch")
    R deleteVideoBatch(@RequestParam("videoIdList") List<String> videoIdList);
}
